<!DOCTYPE html>
<html>
	{include file="head.html"}
	<link href="{$skins}css/news.css" rel="stylesheet" />
	<body>
		<div class="topfixed">
	       <div class="t_left"><a href="/index.php" class="goBack"><i class="back"></i></a></div>
	       <div class="t_main">新鲜事</div>
	   	   <div class="t_right"><a href="/index.php?m=news&a=add" class="link"  >发布</a></div>
	    </div>
	    <div class="paddingheight"></div>
	    {include file="news/news_head.html"}
	    <div class="tabs-border i3">
	    	<a href="/index.php?m=news" class="item active">主页</a>
	    	<a href="/index.php?m=news&a=school" class="item">校园</a>
	    	<a href="/index.php?m=news&a=my" class="item">我的</a>
	    	
	    </div>
	    <div class="main-body">
	     
	    	<div class="newslist" id="newslist">
	    		{foreach item=c from=$data}
	    		{include file="news/item.html"}
	    		{/foreach}
	    	</div>
	    	<div id="loadmore" class="pullup">加载更多</div>
	    </div>
	    {include file="footer.html"}
   		{include file="botnav.html"}
   		{include file="inc/js_thumb.html"}
   		{include file="news/comm.html"}
   		{include file="news/item_tpl.html"}
   		
   		<script src="/plugin/jquery/template-native.js"></script>
 		<script src="/plugin/skyweb/listload.js"></script>
   		<script>
   			var isfrist=false,per_page=24;
   			function getNews(){
   				if(per_page==0) return false;
   				$.get("/index.php?m=news&ajax=1&per_page="+per_page,function(data){
   					per_page=data.data.per_page;
   					if(data.data.data){
   						var html=template("item_tpl",data.data);
   						$("#newslist").append(html);
   					}
   				},"json")
   			}
   			
   			listload.showload(function(){
   				getNews();
   			})
   			
   		</script>
	</body>
</html>
